#!/bin/bash

# gettable.sh

if [ -e "job.out" ] ; then 
 rm -f job.out
fi

echo "fname, segs, intersecs, ilp, g1, g2, g3" > job.out

for inputfile in $* ;

do 
  echo $inputfile processing ;
  ncols=`head -1 $inputfile | wc -w`
  nrows=`cat $inputfile | wc -l`
  nminsol=`ilp $inputfile`
  greedy1=`greedy n sc < $inputfile`
  greedy2=`greedy n vc < $inputfile`
  greedy3=`greedy n ivc < $inputfile`

  echo $inputfile $ncols $nrows $nminsol $greedy1 $greedy2 $greedy3 >> job.out
  
done ;
